.TH MSTLINK "1" "March 2020" "mstflint" "User Commands"
.SH NAME
mstlink \- check and debug link status and issues related to them
.SH
SYNOPSIS
mstlink [OPTIONS]
.SH
DESCRIPTION
The mlxlink tool is used to check and debug link status and issues related to them.
The tool can be used on different links and cables (passive, active, transceiver and backplane).
.SH
OPTIONS
.TP
\fB\-h\fR |\-\-help
: Display help message.
.TP
\fB\-v\fR |\-\-version
: Display version info.
.TP
\fB\-d\fR |\-\-device
<device>               : Perform operation for a specified mst device
.TP
\fB\-p\fR |\-\-port
<port_number>          : Port Number
.TP
\fB\-\-port_type\fR
<port_type>            : Port Type [NETWORK(Default)/PCIE]
.TP
\fB\-\-depth\fR
<depth>                : depth level of the DUT of some hierarchy (PCIE only)
.TP
\fB\-\-pcie_index\fR
<pcie_index>           : PCIe index number (Internal domain index) (PCIE only)
.TP
\fB\-\-node\fR
<node>                 : the node within each depth (PCIE only)
.TP
\fB\-\-json\fR
: Print the output in json format
.IP
QUERIES:
.TP
\fB\-\-show_links\fR
: Show valid PCIe links (PCIE only)
.TP
\fB\-m\fR |\-\-show_module
: Show Module Info
.TP
\fB\-c\fR |\-\-show_counters
: Show Physical Counters and BER Info
.TP
\fB\-e\fR |\-\-show_eye
: Show Eye Opening Info
.TP
\fB\-\-show_fec\fR
: Show FEC Capabilities
.TP
\fB\-\-show_serdes_tx\fR
: Show Transmitter Info
.TP
\fB\-\-show_device\fR
: General Device Info
.TP
\fB\-\-show_ber_monitor\fR
: Show BER Monitor Info (not supported for HCA)
.TP
\fB\-\-show_external_phy\fR
: Show External PHY Info
.IP
COMMANDS:
.TP
\fB\-a\fR |\-\-port_state <port_state>
: Configure Port State [UP(up)/DN(down)/TG(toggle)]
.TP
\fB\-s\fR |\-\-speeds
<speeds>               : Configure Speeds [speed1,speed2,...]
.TP
\fB\-\-link_mode_force\fR
: Configure Link Mode Force (Disable AN)
.TP
\fB\-l\fR |\-\-loopback
<loopback>             : Configure Loopback Mode [NO(no loopback)/PH(phy loopback)/EX(external loopback)]
.TP
\fB\-k\fR |\-\-fec
<fec_override>                 : Configure FEC [AU(Auto)/NF(No\-FEC)/FC(FireCode FEC)/RS(RS\-FEC)]
.TP
\fB\-\-fec_speed\fR
<fec_speed>                : Speed to Configure FEC [100G/50G/25G/...] (Default is Active Speed)
.TP
\fB\-\-serdes_tx\fR
<params>               : Configure Transmitter Parameters [polarity,ob_tap0,...]
.TP
\fB\-\-serdes_tx_lane\fR <transmitter_lane>
: Transmitter Lane to Set (Optional \- Default All Lanes)
.TP
\fB\-\-database\fR
: Save Transmitter Configuration for Current Speed Permanently (Optional)
.TP
\fB\-\-test_mode\fR
<prbs_mode>            : Physical Test Mode Configuration [EN(enable)/DS(disable)/TU(perform tuning)]
.TP
\fB\-\-rx_prbs\fR
<rx_prbs_mode>             : RX PRBS Mode [PRBS31(Default)/PRBS7/...] (Optional \- Default PRBS31)
.TP
\fB\-\-tx_prbs\fR
<tx_prbs_mode>             : TX PRBS Mode [PRBS31(Default)/PRBS7/...] (Optional \- Default PRBS31)
.TP
\fB\-\-rx_rate\fR
<rx_lane_rate>             : RX Lane Rate [EDR(Default)/25G/10G/...]  (Optional \- Default 25G)
.TP
\fB\-\-tx_rate\fR
<tx_lane_rate>             : TX Lane Rate [EDR(Default)/25G/10G/...]  (Optional \- Default 25G)
.TP
\fB\-b\fR |\-\-ber_collect <csv_file>
: Port Extended Information Collection [CSV File]
.TP
\fB\-\-ber_limit\fR
<limit_criteria>           : BER Limit Criteria [Nominal(Default)/Corner/Drift] (Optional \- Default Nominal)
.TP
\fB\-\-iteration\fR
<iteration>                : Iteration Number of BER Collection
.TP
\fB\-\-pc\fR
: Clear Counters
.TP
\fB\-\-set_external_phy\fR
: Set External PHY (not supported for HCA)
.TP
\fB\-\-twisted_pair_force_mode\fR <twisted_pair_force_mode>
: Twisted Pair Force Mode [MA(Master)/SL(Slave)]
.SH
EXAMPLES
.TP
get info of <device>, <port_number>
:
.IP
mstlink \fB\-d\fR <device> \fB\-p\fR <port_number>
.IP
get info of <device>, <port_number> and BER Counters:
.IP
mstlink \fB\-d\fR <device> \fB\-p\fR <port_number> \fB\-c\fR
.IP
get info of <device>, <port_number> and Transmitter Parameters:
.IP
mstlink \fB\-d\fR <device> \fB\-p\fR <port_number> \fB\-\-show_serdes_tx\fR
.TP
Configure Port State
:
.IP
mstlink \fB\-d\fR <device> \fB\-p\fR <port_number> \fB\-\-port_state\fR UP
.TP
Configure Port Speeds
:
.IP
mstlink \fB\-d\fR <device> \fB\-p\fR <port_number> \fB\-\-speeds\fR 25G,50G,100G
.TP
Configure FEC
:
.IP
mstlink \fB\-d\fR <device> \fB\-p\fR <port_number> \fB\-\-fec\fR RS
.TP
Configure Port for Physical Test Mode
:
.IP
mstlink \fB\-d\fR <device> \fB\-p\fR <port_number> \fB\-\-test_mode\fR EN (\fB\-\-rx_prbs\fR PRBS31 \fB\-\-rx_rate\fR 25G \fB\-\-tx_prbs\fR PRBS7 \fB\-\-tx_rate\fR 10G)
.TP
Perform PRBS Tuning
:
.IP
mstlink \fB\-d\fR <device> \fB\-p\fR <port_number> \fB\-\-test_mode\fR TU
.IP
Configure Transmitter Parameters (on lane, to database):
.IP
mstlink \fB\-d\fR <device> \fB\-p\fR <port_number> (\fB\-\-serdes_tx_lane\fR <lane number>) (\fB\-\-database\fR) \\
  \fB\-\-serdes_tx\fR <polarity>,<ob_tap0>,<ob_tap1>,<ob_tap2>,<ob_bias>,<ob_preemp_mode>
.SH "SEE ALSO"
mstflint(1)
